
/************** position color texture *******************/

const char * Shaders::ShaderCode_PositionColorTexture = R"(

cbuffer ConstantBuffer : register(b0)
{
    row_major matrix World; 
    row_major matrix View;  
    row_major matrix Proj;  
}

Texture2D colorMap_ : register( t0 );
SamplerState colorSampler_ : register( s0 );

struct VertexIn
{
    float3 posL : POSITION;
    float4 color : COLOR;
	float2 tex0 : TEXCOORD0;
};

struct VertexOut
{
    float4 posH : SV_POSITION;
    float4 color : COLOR;
	float2 tex0 : TEXCOORD0;
};

VertexOut vs_main(VertexIn pIn)
{
    VertexOut pOut;
    //pOut.posH = mul(float4(pIn.posL, 1.0f), World); 
   // pOut.posH = mul(pOut.posH, View);                   
    //pOut.posH = mul(float4(pIn.posL, 1.0f), Proj);    
	pOut.posH = float4(pIn.posL, 1.0f);         
    pOut.color = pIn.color;    
	pOut.tex0 = pIn.tex0;
    return pOut;
}

float4 ps_main(VertexOut pIn) : SV_Target
{
     return colorMap_.Sample( colorSampler_, pIn.tex0 );
}

)";